<?php 
    //-------------------INPUT ELEMENTS----------------
    $name 		= $this->formText('name',$this->Item['name'],array('class'=>'txtmedium'));
    $picture            = $this->formFile('picture');
    $parents            = $this->cmsSelect('parents', $this->Item['parents'], 
                                                $this->slbCategory, array('size'=>10, 'style'=>'min-width: 200px;'));
    $options		= array('Inactive','Active');
    $status		= $this->formRadio('status',$this->Item['status'],null,$options, ' ');
    $order		= $this->formText('order',$this->Item['order'],array('class'=>'txtshort'));
    
    $options = $this->slbGroup;
    $slbGroup = $this->formSelect('group_id', $this->Item['group_id'],array('style'=>"min-width: 200px"),$options);
    $sign = $this->cmsReplaceString($this->Item['sign']);
    $sign = $this->cmsEditor('sign',$sign,array('toolbar'=>'Default','language'=>'vi'));
//    echo $this->Item['sign'];
    $arrInput = array(
                        array('label'=>'Category name: ', 'input'=>$name),
                        array('label'=>'Picture: ', 'input'=>$picture),
                        array('label'=>'Parents: ', 'input'=>$parents),
                        array('label'=>'Status: ', 'input'=>$status),
                        array('label'=>'Sign: ', 'input'=>$order)
                        );
    //------------------------MESSAGES ERROR----------------------
    if(count($this->messageError) > 0){
        $error = $this->formErrors($this->messageError, array('id'=>'errors'));		
    }
    
    
?>
<form name="appForm" method="post" action="" enctype="multipart/form-data">
    
                        <?php echo $this->render('admin-category/toolbar/index.php') ;?>
                        <?php // include_once 'toolbar/index.php';?>
                        <div class="clr"></div>
                        <?php echo $this->render('admin-category/sublink/index.php') ;?>
                        <?php echo $error;?>
                        <!-- BEGIN: CONTENT -->
                        <div id="element-box">
                            <div class="t">
                                <div class="t">
                                    <div class="t"></div>
                                </div>
                            </div>
                            <div class="m">
                                <!-- BEGIN: ELEMENT BOX -->
                                <div id="adminfieldset">
                                    <div class="adminheader">Detail</div>
                                    <?php echo $this->partialLoop('row.php', $arrInput);?>
                                    
                                </div>
                                <!-- Area 4: In du lieu lay tu database -->
                                
                                <!-- Area 4: In du lieu lay tu database - End -->

                                <!-- END: ELEMENT BOX -->	
                                <div class="clr"></div>
                            </div>
                            <div class="b">
                                <div class="b">
                                    <div class="b"></div>
                                </div>
                            </div>
                        </div>
                        <!-- END: 	CONTENT -->
                    </form>